package com.ram.mapper;

import com.ram.pojo.Room;
import com.ram.pojo.RoomDTO;
import com.ram.pojo.RoomVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;

@Mapper
public interface RoomMapper {
    List<Room> list(Integer buildingId);
    Room getById(Integer id);
    void insert(Room room);
    void update(Room room);
    void deleteById(Integer id);

    // 分页+条件查询
    List<RoomVO> pageQuery(RoomDTO dto);
    long countPageQuery(RoomDTO dto);

    // 业务联动
    void updateStatus(@Param("roomId") Integer roomId, @Param("status") int status);
} 